Optimal. Leaf size=144 \[ \frac {b \left (3 a^2+3 a b+b^2\right ) \tan ^3(c+d x)}{3 d}-\frac {b \left (3 a^2+3 a b+b^2\right ) \tan (c+d x)}{d}+\frac {b^2 (3 a+b) \tan ^7(c+d x)}{7 d}-\frac {b^2 (3 a+b) \tan ^5(c+d x)}{5 d}+x (a+b)^3+\frac {b^3 \tan ^{11}(c+d x)}{11 d}-\frac {b^3 \tan ^9(c+d x)}{9 d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.08, antiderivative size = 144, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.214, Rules used = {3661, 1154, 203} \[ \frac {b \left (3 a^2+3 a b+b^2\right ) \tan ^3(c+d x)}{3 d}-\frac {b \left (3 a^2+3 a b+b^2\right ) \tan (c+d x)}{d}+\frac {b^2 (3 a+b) \tan ^7(c+d x)}{7 d}-\frac {b^2 (3 a+b) \tan ^5(c+d x)}{5 d}+x (a+b)^3+\frac {b^3 \tan ^{11}(c+d x)}{11 d}-\frac {b^3 \tan ^9(c+d x)}{9 d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 203
Rule 1154
Rule 3661
Rubi steps
\begin {align*} \int \left (a+b \tan ^4(c+d x)\right )^3 \, dx &=\frac {\operatorname {Subst}\left (\int \frac {\left (a+b x^4\right )^3}{1+x^2} \, dx,x,\tan (c+d x)\right )}{d}\\ &=\frac {\operatorname {Subst}\left (\int \left (-b \left (3 a^2+3 a b+b^2\right )+b \left (3 a^2+3 a b+b^2\right ) x^2-b^2 (3 a+b) x^4+b^2 (3 a+b) x^6-b^3 x^8+b^3 x^{10}+\frac {(a+b)^3}{1+x^2}\right ) \, dx,x,\tan (c+d x)\right )}{d}\\ &=-\frac {b \left (3 a^2+3 a b+b^2\right ) \tan (c+d x)}{d}+\frac {b \left (3 a^2+3 a b+b^2\right ) \tan ^3(c+d x)}{3 d}-\frac {b^2 (3 a+b) \tan ^5(c+d x)}{5 d}+\frac {b^2 (3 a+b) \tan ^7(c+d x)}{7 d}-\frac {b^3 \tan ^9(c+d x)}{9 d}+\frac {b^3 \tan ^{11}(c+d x)}{11 d}+\frac {(a+b)^3 \operatorname {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,\tan (c+d x)\right )}{d}\\ &=(a+b)^3 x-\frac {b \left (3 a^2+3 a b+b^2\right ) \tan (c+d x)}{d}+\frac {b \left (3 a^2+3 a b+b^2\right ) \tan ^3(c+d x)}{3 d}-\frac {b^2 (3 a+b) \tan ^5(c+d x)}{5 d}+\frac {b^2 (3 a+b) \tan ^7(c+d x)}{7 d}-\frac {b^3 \tan ^9(c+d x)}{9 d}+\frac {b^3 \tan ^{11}(c+d x)}{11 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 1.07, size = 128, normalized size = 0.89 \[ \frac {b \tan (c+d x) \left (1155 \left (3 a^2+3 a b+b^2\right ) \tan ^2(c+d x)-3465 \left (3 a^2+3 a b+b^2\right )+495 b (3 a+b) \tan ^6(c+d x)-693 b (3 a+b) \tan ^4(c+d x)+315 b^2 \tan ^{10}(c+d x)-385 b^2 \tan ^8(c+d x)\right )}{3465 d}+\frac {(a+b)^3 \tan ^{-1}(\tan (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.87, size = 145, normalized size = 1.01 \[ \frac {315 \, b^{3} \tan \left (d x + c\right )^{11} - 385 \, b^{3} \tan \left (d x + c\right )^{9} + 495 \, {\left (3 \, a b^{2} + b^{3}\right )} \tan \left (d x + c\right )^{7} - 693 \, {\left (3 \, a b^{2} + b^{3}\right )} \tan \left (d x + c\right )^{5} + 1155 \, {\left (3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \tan \left (d x + c\right )^{3} + 3465 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} d x - 3465 \, {\left (3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \tan \left (d x + c\right )}{3465 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.03, size = 252, normalized size = 1.75 \[ \frac {b^{3} \left (\tan ^{11}\left (d x +c \right )\right )}{11 d}-\frac {b^{3} \left (\tan ^{9}\left (d x +c \right )\right )}{9 d}+\frac {3 \left (\tan ^{7}\left (d x +c \right )\right ) a \,b^{2}}{7 d}+\frac {\left (\tan ^{7}\left (d x +c \right )\right ) b^{3}}{7 d}-\frac {3 a \,b^{2} \left (\tan ^{5}\left (d x +c \right )\right )}{5 d}-\frac {b^{3} \left (\tan ^{5}\left (d x +c \right )\right )}{5 d}+\frac {\left (\tan ^{3}\left (d x +c \right )\right ) a^{2} b}{d}+\frac {a \,b^{2} \left (\tan ^{3}\left (d x +c \right )\right )}{d}+\frac {b^{3} \left (\tan ^{3}\left (d x +c \right )\right )}{3 d}-\frac {3 a^{2} b \tan \left (d x +c \right )}{d}-\frac {3 a \,b^{2} \tan \left (d x +c \right )}{d}-\frac {b^{3} \tan \left (d x +c \right )}{d}+\frac {\arctan \left (\tan \left (d x +c \right )\right ) a^{3}}{d}+\frac {3 \arctan \left (\tan \left (d x +c \right )\right ) a^{2} b}{d}+\frac {3 \arctan \left (\tan \left (d x +c \right )\right ) a \,b^{2}}{d}+\frac {\arctan \left (\tan \left (d x +c \right )\right ) b^{3}}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.77, size = 167, normalized size = 1.16 \[ a^{3} x + \frac {{\left (\tan \left (d x + c\right )^{3} + 3 \, d x + 3 \, c - 3 \, \tan \left (d x + c\right )\right )} a^{2} b}{d} + \frac {{\left (15 \, \tan \left (d x + c\right )^{7} - 21 \, \tan \left (d x + c\right )^{5} + 35 \, \tan \left (d x + c\right )^{3} + 105 \, d x + 105 \, c - 105 \, \tan \left (d x + c\right )\right )} a b^{2}}{35 \, d} + \frac {{\left (315 \, \tan \left (d x + c\right )^{11} - 385 \, \tan \left (d x + c\right )^{9} + 495 \, \tan \left (d x + c\right )^{7} - 693 \, \tan \left (d x + c\right )^{5} + 1155 \, \tan \left (d x + c\right )^{3} + 3465 \, d x + 3465 \, c - 3465 \, \tan \left (d x + c\right )\right )} b^{3}}{3465 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 11.66, size = 180, normalized size = 1.25 \[ \frac {{\mathrm {tan}\left (c+d\,x\right )}^3\,\left (a^2\,b+a\,b^2+\frac {b^3}{3}\right )}{d}+\frac {\mathrm {atan}\left (\frac {\mathrm {tan}\left (c+d\,x\right )\,{\left (a+b\right )}^3}{a^3+3\,a^2\,b+3\,a\,b^2+b^3}\right )\,{\left (a+b\right )}^3}{d}-\frac {b^3\,{\mathrm {tan}\left (c+d\,x\right )}^9}{9\,d}+\frac {b^3\,{\mathrm {tan}\left (c+d\,x\right )}^{11}}{11\,d}-\frac {\mathrm {tan}\left (c+d\,x\right )\,\left (3\,a^2\,b+3\,a\,b^2+b^3\right )}{d}-\frac {{\mathrm {tan}\left (c+d\,x\right )}^5\,\left (\frac {b^3}{5}+\frac {3\,a\,b^2}{5}\right )}{d}+\frac {{\mathrm {tan}\left (c+d\,x\right )}^7\,\left (\frac {b^3}{7}+\frac {3\,a\,b^2}{7}\right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 3.18, size = 224, normalized size = 1.56 \[ \begin {cases} a^{3} x + 3 a^{2} b x + \frac {a^{2} b \tan ^{3}{\left (c + d x \right )}}{d} - \frac {3 a^{2} b \tan {\left (c + d x \right )}}{d} + 3 a b^{2} x + \frac {3 a b^{2} \tan ^{7}{\left (c + d x \right )}}{7 d} - \frac {3 a b^{2} \tan ^{5}{\left (c + d x \right )}}{5 d} + \frac {a b^{2} \tan ^{3}{\left (c + d x \right )}}{d} - \frac {3 a b^{2} \tan {\left (c + d x \right )}}{d} + b^{3} x + \frac {b^{3} \tan ^{11}{\left (c + d x \right )}}{11 d} - \frac {b^{3} \tan ^{9}{\left (c + d x \right )}}{9 d} + \frac {b^{3} \tan ^{7}{\left (c + d x \right )}}{7 d} - \frac {b^{3} \tan ^{5}{\left (c + d x \right )}}{5 d} + \frac {b^{3} \tan ^{3}{\left (c + d x \right )}}{3 d} - \frac {b^{3} \tan {\left (c + d x \right )}}{d} & \text {for}\: d \neq 0 \\x \left (a + b \tan ^{4}{\relax (c )}\right )^{3} & \text {otherwise} \end {cases} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________